<template>
  <div>
    <p>{{ $store.state.count }}</p>
    <button @click="$store.commit('add')">+1</button>
    <button
      @click="
        $store.commit('addN', {
          num1: 3,
          num2: 8
        })
      "
    >
      +N
    </button>
    <button @click="$store.dispatch('addAsync')">async +1</button>
    <button
      @click="
        $store.dispatch('addNAsync', {
          num2: 5
        })
      "
    >
      async +5
    </button>
    <p>{{ $store.getters.showNum }}</p>
  </div>
</template>

<script>
export default {
  data() {
    return {}
  }
}
</script>
